<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<title>查看订单信息</title>
		<link rel="stylesheet" type="text/css"
			href="../css/commonBookTest.css">
		<style type="text/css">
			body {
				font-family: 华文楷体;
				color: #ffffff;
				font-size: 16px;
				background-color: #556b2f;
				line-height: 33px;
			}
			
			a:active {
				color: #ffffff;
				text-decoration: none;
			}
			
			a:visited {
				color: #96CFFC;
				text-decoration: none;
			}
			
			a:hover {
				color: yellow;
				text-decoration: underline;
			}
		</style>
	</head>
	<body>
		<center>
			<table border="0" width="70%">
				<tr>
					<td align="center">
						&nbsp;
						<font face="华文行楷" size="5">查看订单信息 </font>
					</td>
				</tr>

				<tr>
					<td>
						<table width="100%" border="1">
							<tr>
								<td colspan="4">
									<strong>订单信息</strong>
								</td>
							</tr>
							<tr>
								<td width="15%" align="right">
									订单编号&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td width="35%" align="left">
									${orderForm.orderId}
								</td>
								<td colspan="2" width="50%">
									<a
										href="${CONTEXT_ROOT}/SysOrderFormServlet?method=${method}&orderState=${orderForm.orderState}">返回列表</a>
								</td>
							</tr>
							<tr>
								<td width="15%" align="right">
									订单状态&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td width="35%" align="left">
									${state}
								</td>
								<td align="right" width="15%">
									下单时间&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left" width="35%">
									${orderForm.orderSumitDate}
									<br>
								</td>
							</tr>
							<tr>
								<td align="right">
									总金额&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.totalMoney}
								</td>
								<td align="right">
									发货时间&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.orderSendDate}
									<br>
								</td>
							</tr>
							<tr>
								<td align="right">
									会员金额&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.memberMoney}
								</td>
								<td align="right">
									收货时间&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.orderAcceptDate}
									<br>
								</td>
							</tr>

							<tr>
								<td align="right">
									会员ID&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.memberId}
								</td>
								<td align="right">
									订单取消时间&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.orderCancelDate}
									<br>
								</td>
							</tr>
							<tr>
								<td align="right">
									收货人&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left" colspan="3">
									${orderForm.orderAcceptPerson}
								</td>
							</tr>
							<tr>
								<td align="right">
									联系电话&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.orderAcceptTel}
									<br>
								</td>
								<td align="right">
									手机&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.orderAcceptMobile}
									<br>
								</td>
							</tr>

							<tr>
								<td align="right">
									收货地址&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left" colspan="3">
									${orderForm.orderAcceptProvince}${orderForm.orderAcceptAddr}
									<br>
								</td>
							</tr>
							<tr>
								<td align="right">
									邮政编码&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.orderAcceptZip}
									<br>
								</td>
								<td align="right">
									联系邮箱&nbsp;&nbsp;&nbsp;&nbsp;
								</td>
								<td align="left">
									${orderForm.orderAcceptEmail}
									<br>
								</td>
							</tr>
							<tr>
								<td colspan="4">
									<p>
										* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
										*
									</p>
								</td>
							</tr>

							<tr>
								<td colspan="2">
									<table border="1" width="100%" frame="void">
										<tr style="font-family: 华文行楷;">
											<td width="30%">
												图书编号
											</td>

											<td width="35%">
												图书名称
											</td>
											<td width="35%">
												作者
											</td>
										</tr>
										<tr>
											<td colspan="3">
												<c:forEach items="${bookList}" var="book">
													<tr>
														<td>
															${book.bookId}
															<br>
														</td>
														<td>
															<a
																href="${CONTEXT_ROOT}/SysBookServlet?method=view&bookId=${book.bookId}&publishId=${book.publishId}&categoryId=${book.categoryId}&q=order">${book.bookName}</a>
															<br>
														</td>
														<td>
															${book.bookAuthor}
														</td>
													</tr>
												</c:forEach>
											</td>
										</tr>
									</table>
								</td>
								<td colspan="2">
									<table border="1" width="100%" frame="void">

										<tr>
											<td width="15%">
												数量
											</td>
											<td width="30%">
												单价
											</td>
											<td width="30%">
												会员价
											</td>
											<td width="25%">
												单品会员总价
											</td>
										</tr>
										<tr>
											<td colspan="2">
												<c:forEach items="${orderItemList}" var="orderItem">
													<tr>
														<td>
															${orderItem.bookAmount}
															<br>
														</td>

														<td>
															<fmt:formatNumber value="${orderItem.bookPrice}"
																pattern=".##" />
															<br>
														</td>
														<td>
															<fmt:formatNumber value="${orderItem.memberPrice}"
																pattern=".##" />
															<br>
														</td>
														<td>
															<fmt:formatNumber
																value="${orderItem.memberPrice*orderItem.bookAmount}"
																pattern=".##" />
															<br>
														</td>
													</tr>
												</c:forEach>
											</td>
										</tr>
									</table>
								</td>
							</tr>
							<tr>
								<td colspan="4">
									<p>
										* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
										*
									</p>
								</td>
							</tr>
						</table>
					</td>
				</tr>
			</table>
		</center>
	</body>
</html>